package com.supermate.supercut.app.enums;

import com.supermate.init.exceptions.BusinessException;
import com.supermate.init.exceptions.SystemException;

/**
 * @Author: 冰岩
 * @Date: 2023/10/28
 * @Description:
 */
public class ExceptionsGetter {

    public static SystemException getSysException(ErrorEnums errorEnums) {
        return new SystemException(errorEnums.getErrCode(), errorEnums.getErrMsg());
    }

    public static BusinessException getBizException(ErrorEnums errorEnums) {
        return new BusinessException(errorEnums.getErrCode(), errorEnums.getErrMsg());
    }

}
